package cn.edu.cxcyzx.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.edu.cxcyzx.entity.Progress_project;
import cn.edu.cxcyzx.service.Project_progressService;
import cn.edu.cxcyzx.supervisor.DaoFit;
import cn.edu.cxcyzx.supervisor.ResultDo;

@Service("Project_progressService")
public class Project_progressServiceImpl implements Project_progressService {
	@Resource
	public DaoFit daoFit;
	
	@Override
	public ResultDo<List<Progress_project>> getProgress(int projectId) {
		// TODO Auto-generated method stub
		ResultDo<List<Progress_project>> resultDo=new ResultDo<>();
		List<Progress_project> list=daoFit.getProgress_projectDao().getProgress(projectId);
		if(list!=null&&list.size()>0){
			resultDo.setResult(list);
			resultDo.setSuccess(true);
		}else{
			resultDo.setSuccess(false);
		}
		return resultDo;
	}

}
